<%@ Page Language="C#" AutoEventWireup="true" MasterPageFile="~/Administration/main.master"
    CodeFile="Manufacturers.aspx.cs" Inherits="Tathata.Web.Administration.Administration_Manufacturers" %>

<asp:Content ID="c1" ContentPlaceHolderID="cph1" runat="Server">
    <h4>
        Manufacturers</h4>
    <table class="adminContent">
        <tr>
            <td colspan="2">
                <asp:Button runat="server" Text="Export to XML" CssClass="adminButton" ID="btnExportXML"
                    OnClick="btnExportXML_Click" ValidationGroup="ExportXML" ></asp:Button>
            </td>
        </tr>
    </table>
    <br /><br />
    <asp:GridView ID="gvManufacturers" runat="server" AutoGenerateColumns="False" Width="100%">
        <Columns>
            <asp:BoundField DataField="ManufacturerID" HeaderText="Manufacturer ID" Visible="False">
            </asp:BoundField>
            <asp:TemplateField HeaderText="Name" ItemStyle-Width="60%">
                <ItemTemplate>
                    <a href="ManufacturerDetails.aspx?ManufacturerID=<%#Eval("ManufacturerID")%>">
                        <%#Server.HtmlEncode(Eval("Name").ToString())%>
                    </a>
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Edit" HeaderStyle-HorizontalAlign="Center" ItemStyle-Width="20%"
                ItemStyle-HorizontalAlign="Center">
                <ItemTemplate>
                    <a href="ManufacturerDetails.aspx?ProductID=<%#Eval("ManufacturerID")%>">Edit </a>
                </ItemTemplate>
            </asp:TemplateField>
            <asp:BoundField DataField="Published" HeaderText="Published" HeaderStyle-HorizontalAlign="Center"
                ItemStyle-Width="20%" ItemStyle-HorizontalAlign="Center"></asp:BoundField>
        </Columns>
    </asp:GridView>
    <br>
    <input type="button" onclick="location.href='ManufacturerAdd.aspx'" value="Add new"
        id="btnAddNew" class="adminButton" />
    <br />
</asp:Content>
